<%--
  Created by IntelliJ IDEA.
  User: xujc
  Date: 6/14/15
  Time: 17:54
  To change this template use File | Settings | File Templates.
--%>
<%@ page contentType="text/html;charset=UTF-8" language="java" %>
<%@ taglib prefix="s" uri="/struts-tags" %>
<html>
<head>
    <title>欢迎来到某论坛</title>
    <meta http-equiv="Content-Type" content="text/html" charset="utf-8"/>
</head>
<body>
<%@ include file="userheader.jsp"%>
<div id="header">
    <h1>某论坛欢迎你</h1>
</div>
<div>
    <h2><s:property value="form.name"/></h2>
</div>
<div>
    <a href="/s/index">返回</a>
</div>
<table>
    <tr>
        <td>
            主题
        </td>
        <td>
            楼主
        </td>
        <td>
            最后回复
        </td>
        <td>
            发帖时间
        </td>
    </tr>
    <s:iterator value="form.discusesByFId" var="enti">
        <tr>
            <td>
                <a href="discus?did=${enti.DId}"><s:property value="#enti.content"/></a>
            </td>
            <td>
                <s:property value="#enti.userByUId.userName"/>
            </td>
            <td>
                <s:date name="#enti.lastEdit" format="MM-dd HH:mm"/>
            </td>
            <td>
                <s:date name="#enti.publishTime" format="MM-dd HH:mm"/>
            </td>
        </tr>
    </s:iterator>
</table>

<div>
    <s:if test="#request.logined">
        <s:form action="publish" method="post">
            <s:textfield name="content" label="content"/>
            <s:textfield type="hidden" value="%{form.fId}" name="fid"/>
            <s:textfield type="hidden" value="%{#request.userEnti.uId}" name="fuckid"/>
            <s:submit value="submit"/>
        </s:form>
    </s:if>
</div>
</body>
</html>
